package com.learn.lombok.fieldNameConstants;

import lombok.AccessLevel;
import lombok.experimental.FieldNameConstants;


public class FieldNameConstantsEntity {

    @FieldNameConstants(
        // 生成字段的访问修饰符
        level = AccessLevel.PUBLIC
        // 是否使用枚举生成
        , asEnum = false
        // 生成的枚举字段名(默认为 Fields)
        , innerTypeName = "Fields"
        // 只包含 @FieldNameConstants.Include 标记字段
        , onlyExplicitlyIncluded = false
    )
    public static class NoEnum {
        private String id;
        private String name;
        private String age;
        @FieldNameConstants.Exclude
        private String exclude;
    }

    @FieldNameConstants(
        // 生成字段的访问修饰符
        level = AccessLevel.PUBLIC
        // 是否使用枚举生成(默认false)
        , asEnum = true
        // 生成的枚举字段名(默认为 Fields)
        , innerTypeName = "Fields"
        // 只包含 @FieldNameConstants.Include 标记字段
        , onlyExplicitlyIncluded = false
    )
    public static class Enum {
        private String id;
        private String name;
        private String age;
        @FieldNameConstants.Exclude
        private String exclude;
    }
}
